 <script type="text/javascript">
 $(document).ready(function(){
	$("#btn-pertanyaan").click(function(){
		$("#div-konsultasi").show();
	});
 
 });
 </script>
 
 <div class="col-md-7">
       
    <div class="col-md-11" style="margin-top:25px;">
        

                
                <br />
                <span class="spanjudulberita">
                   <h4><strong>Konsultasi Hukum</strong></h4>
                </span>
                <br />
           
    
    </div>            

    <br />
    <br />

    <div class="col-md-11" style="margin-top:10px;">
	
				<div >&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                <button class="btn btn-success" name="yt0" type="submit" id="btn-pertanyaan">
                <!--<i class="icon-save icon-white"></i>-->
                Ajukan Pertanyaan
                </button>
                </div>
				<br />
					<?php
					if($_REQUEST['success']==1){
					?>
					<div class="row">
					<div class="col-md-10">
					<div class="alert alert-success fade in">
					<i class="icon-remove close" data-dismiss="alert"></i>
					<strong><h4>Terima Kasih Telah Melakukan Konsultasi Hukum</h4></strong>
					</div>
					</div>
					</div>
					<?php
					}
					?>

                <div class="spanpengaduan" style="display:none;" id="div-konsultasi">
                
                <form action="<?php echo Yii::app()->createUrl('konsultasiHukum/index'); ?>" method="post">
                Nama
                <div class="controls">
                <input id="Pengaduan_nama_pelapor" class="span3" type="text" name="KonsultasiHukum[nama]" maxlength="200">
                </div> 


                Alamat
                <div class="controls">
                <input id="Pengaduan_nama_pelapor" class="span5" type="text" name="KonsultasiHukum[alamat]" maxlength="200">
                </div>              


                Email
                <div class="controls">
                <input id="Pengaduan_nama_pelapor" class="span3" type="text" name="KonsultasiHukum[email]" maxlength="200">
                </div>             


                Telp 
                <div class="controls">
                <input id="Pengaduan_nama_pelapor" class="span3" type="text" name="KonsultasiHukum[telp]" maxlength="200">
                </div>             



                Judul Pertanyaan
                <div class="controls">
                <input id="Pengaduan_nama_pelapor" class="span4" type="text" name="KonsultasiHukum[judul]" maxlength="200">
                </div> 


                Isi Pertanyaan
                <div class="controls">
                    <textarea id="Posting_deskripsi" name="KonsultasiHukum[isi]" class="span5" cols="40" rows="2"></textarea>
                </div> 


                <div style="text-align:center">
                <button id="yw0" class="btn btn-primary" name="yt0" type="submit">
                <i class="icon-ok icon-white"></i>
                Kirim
                </button>
                </div>

                </form>
                </div>
				
				
				
				<div class="spanpengaduan">
				 <strong><h4>Daftar Konsultasi</h4></strong>
				 
				 
				<?php
				$konsultasi = KonsultasiHukum::model()->findAll(array('order'=>'created_time desc'));

				foreach($konsultasi as $row){
				?>
				<div class="div-indexpengumuman3">
					<span class="tglpengumuman">
						
						<?php echo date('d-m-Y',strtotime($row->created_time)) ?>
						<br />
						<?php echo $row->nama; ?>
					</span>
					<br />
					
					<span class="judulpengumuman">
						<a href="<?php echo Yii::app()->createUrl('konsultasiHukum/view',array('id'=>$row->id)); ?>" >
						<?php echo $row->judul ?>
						</a>
					</span>

				</div>    
				
				
				<hr class="hrpengumuman" />
				
				
				<?php
				}
				?> 
				</div>	



    </div>            

</div>

